﻿<%@ Page Title="" Language="C#" MasterPageFile="~/UserMasterPage.Master" AutoEventWireup="true"
    CodeBehind="PolicyInsurance.aspx.cs" Inherits="InsuranceVehicle.PolicyInsurance" %>

<%@ Register Src="UserMenuControl.ascx" TagName="UserMenuControl" TagPrefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="title" runat="server">
    Policy Insurance
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="menuPlace" runat="server">
    <uc1:UserMenuControl ID="UserMenuControl1" runat="server" SelectedMenu="policy" ShowElement="all" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="mainContent" runat="server">
    <asp:Panel ID="panelPolicy" runat="server">
        <center>
            <h2 style="font-size: 25px">
                Please, enter your information to Buy Insurance.</h2>
            
            <asp:Label ID="lblNotice" runat="server" Visible="false" Font-Italic="true" Font-Bold="true" Font-Size="Large" ForeColor="Red"></asp:Label>
        </center>
        <br />
        <%-------------------------------Choose vehicle ------------------------------%>
        <asp:Panel ID="panelVehicleInfo" runat="server">
            <div style="width: 500px; margin: auto;">
                <h2>
                    Enter Vehicle Infomations</h2>
                <%---------%>
                <div style="text-align: center">
                    <asp:ValidationSummary ID="ValidationSummary1" runat="server" Font-Italic="True"
                        Font-Size="Medium" ForeColor="Red" />
                    <asp:Label ID="lblError" runat="server" Text="lblError" Font-Italic="True" Font-Size="Medium"
                        ForeColor="Red" Visible="false"></asp:Label>
                </div>
                <%---------%>
                <asp:Label ID="model" runat="server" Text="Model" CssClass="label"></asp:Label><br />
                <asp:DropDownList ID="cbbVehicleType" runat="server" CssClass="dropdown" Width="300px"
                    ToolTip="Choose your vehicle">
                    <asp:ListItem>Choose your vehicle</asp:ListItem>
                </asp:DropDownList>
                <p>
                </p>
                <asp:Label ID="year" runat="server" CssClass="label" Text="Bought in"></asp:Label><br />
                <asp:DropDownList ID="cbbYearOfVehicle" runat="server" CssClass="dropdown" Width="300px"
                    ToolTip="Choose ">
                    <asp:ListItem>Choose</asp:ListItem>
                </asp:DropDownList>
                <%---------%>
                <p>
                </p>
                <asp:Label ID="Label1" runat="server" Text="Control Plate" CssClass="label"></asp:Label><br />
                <asp:TextBox ID="txtControlPlate" CssClass="text" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtControlPlate"
                    Display="None" ErrorMessage="Please, enter control plate" SetFocusOnError="True"></asp:RequiredFieldValidator>
                <%---------%>
                <p>
                </p>
                <asp:Label ID="Label7" runat="server" Text="Price (USD)" CssClass="label"></asp:Label><br />
                <asp:TextBox ID="txtPrice" CssClass="text" runat="server"></asp:TextBox>
                <asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" ControlToValidate="txtPrice"
                    Display="None" ErrorMessage="Please, enter price of vehicle" SetFocusOnError="True"></asp:RequiredFieldValidator>
                <%---------%>
                <br />
                <br />
                <center>
                    <asp:Button ID="btnNext" runat="server" Text="Next" CssClass="button" CausesValidation="false"
                        OnClick="btnNext_Click" />
                </center>
            </div>
        </asp:Panel>
        <%-------------------------------Choose insurance ------------------------------%>
        <asp:Panel ID="panelInsuranceInfo" runat="server">
            <div style="width: 500px; margin: auto;">
                <%---------%>
                <h2>
                    Enter Insurance Infomations</h2>
                <asp:Label ID="Label9" runat="server" CssClass="label" Text="Insurance type"></asp:Label><br />
                <asp:DropDownList ID="cbbInsuType" runat="server" CssClass="dropdown" Width="300px"
                    AutoPostBack="True" OnSelectedIndexChanged="cbbInsuType_SelectedIndexChanged">
                    <asp:ListItem>Choose one type</asp:ListItem>
                </asp:DropDownList>
                <asp:Label ID="lblErrChooseInsurance" runat="server" ForeColor="Red" Font-Italic="True"></asp:Label>
                <br />
                <br />
                <%---------%>
                <asp:Label ID="chooseYear" runat="server" CssClass="label" Text="Duration (Year)"></asp:Label><br />
                <asp:DropDownList ID="cbbDuration" runat="server" CssClass="dropdown" Width="300px"
                    OnSelectedIndexChanged="cbbDuration_SelectedIndexChanged" AutoPostBack="True">
                    <asp:ListItem>Choose </asp:ListItem>
                </asp:DropDownList>
                <asp:Label ID="lblErrChooseYear" runat="server" ForeColor="Red" Font-Italic="True"></asp:Label>
                <br />
                <br />
                <%---------%>
                <asp:Label ID="Label2" runat="server" CssClass="label" BackColor="Gray" Text="Description about this Insurance"></asp:Label><br />
                <div style="padding: 10px; border: 2px solid gray">
                    <asp:Literal ID="showDescription" runat="server"></asp:Literal>
                </div>
                <asp:CheckBox ID="checkBoxAccept" runat="server" CssClass="checkbox" Text="I read and accept" />
                <br />
                <asp:Label ID="lblErrConfirm" runat="server" Visible="false" ForeColor="Red" Font-Italic="True"></asp:Label>
                <br />
                <asp:Label ID="Label4" runat="server" CssClass="label" Text="Amount:  "></asp:Label>
                <asp:Label ID="lblAmount" runat="server" CssClass="label" Font-Size="Large"></asp:Label>
                <asp:Label ID="lblAmountNumber" runat="server" Visible="False"></asp:Label>
                <br />
                <br />
                <asp:RadioButton ID="rdPayOnline" runat="server" Text="Payment Online" GroupName="payment"
                    AutoPostBack="true" OnCheckedChanged="rdPayOnline_CheckedChanged" />
                &nbsp;&nbsp;&nbsp;
                <asp:RadioButton ID="rdpayOffline" runat="server" Text="Payment Directly" GroupName="payment"
                    OnCheckedChanged="rdpayOffline_CheckedChanged" AutoPostBack="true" 
                    Checked="True" />
                <br />
                <br />
                <asp:Panel ID="panelPayOnline" runat="server" Visible="false">
                    <asp:Label ID="Label3" runat="server" Text="Account name" CssClass="label"></asp:Label><br />
                    <asp:TextBox ID="txtAccName" CssClass="text" runat="server"></asp:TextBox>
                    <asp:Label ID="lblErrAccName" runat="server" Visible="false" ForeColor="Red" Font-Italic="True"></asp:Label>
                    <br />
                    <br />
                    <asp:Label ID="Label5" runat="server" Text="Account number" CssClass="label"></asp:Label><br />
                    <asp:TextBox ID="txtAccNum" CssClass="text" runat="server"></asp:TextBox>
                    <asp:Label ID="lblErrAccNum" runat="server" Visible="false" ForeColor="Red" Font-Italic="True"></asp:Label>
                    
                </asp:Panel>
                <br />
                <center>
                    <asp:Button ID="btnSubmit" runat="server" Text="Submit" CssClass="button" CausesValidation="false"
                        OnClick="btnSubmit_Click" />
                    
                    
                </center>
            </div>
        </asp:Panel>
    </asp:Panel>
    <asp:Panel ID="panelError" runat="server">
        <center>
            <h2 style="font-size: 20px; color: red">
                <asp:Label ID="lblErrLogin" runat="server"></asp:Label>
            </h2>
        </center>
    </asp:Panel>
</asp:Content>
